package decoration;

public class Milk extends CondimentDecorator{
    private Drink drink;

    public Milk(Drink drink) {
        this.drink = drink;
    }

    //获得咖啡的基本描述+配料名
    @Override
    public String getDescription() {
        return drink.getDescription()+",加milk$2";
    }
    //计算咖啡基本价钱+配料milk价钱
    @Override
    public double cost() {
        return drink.cost()+2;
    }
}
